package com.ddm.entity.vxEntity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.ddm.enumeration.QuestionType;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.apache.ibatis.type.EnumOrdinalTypeHandler;
import org.apache.ibatis.type.EnumTypeHandler;

import java.io.Serializable;

/**
 * <p>
 * 
 * </p>
 *
 * @author horizon
 * @since 2025-01-17
 */
@Data
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="Quetsions对象", description="")

public class Question implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "试题表id")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "标准表id")
    private Long standardId;

    @ApiModelProperty(value = "试题内容")
    private String questionContent;

    @ApiModelProperty(value = "选项1")
    private String questionSelection1;

    @ApiModelProperty(value = "选项2")
    private String questionSelection2;

    @ApiModelProperty(value = "选项3")
    private String questionSelection3;

    @ApiModelProperty(value = "选项4")
    private String questionSelection4;

    @ApiModelProperty(value = "答案解析")
    private String questionAnalysis;

    @ApiModelProperty(value = "试题分值")
    private Integer questionScore;

    @ApiModelProperty(value = "0为单选题 ， 1为多选题 ，其中selection1,2,3,4分别代表ABCD")
    @TableField(typeHandler = EnumTypeHandler.class)
    private QuestionType questionType;

    @ApiModelProperty(value = "答案")
    private String answer;

}
